# !/usr/bin/env python
# -*- coding:utf-8 -*-
# @FileName  :user.py
# @Time      :2022/5/30 15:58
# @Author    :张志坤
# 自定义序列化的字段
from flask_restful import fields

# 用户
user_fields = {
    "uid": fields.Integer,
    'account': fields.String,
    "user_name": fields.String,
    "create_date": fields.DateTime,
    'gender': fields.Integer,
    'profile_photo': fields.String,
}
# 频道
channel_fields = {
    "cid": fields.Integer,
    'cname': fields.String,
    "sequence": fields.Integer,
    'ctime': fields.DateTime
}

# 评论
comment_fields = {
    "content": fields.String,
    'title': fields.String,
    'ctime': fields.DateTime,
}

# 文章
news_fields = {
    'user_id': fields.Integer,
    "nid": fields.Integer,
    'title': fields.String,
    'cover': fields.String,
    'content': fields.String,
    'comment_count': fields.Integer,
    'good_count': fields.Integer,
    'ctime': fields.DateTime

}
